package app.sevenc.module_welcome

import android.Manifest
import androidx.appcompat.app.AppCompatActivity
import android.os.Bundle
import androidx.lifecycle.lifecycleScope
import app.sevenc.lib_base.mvvm.v.BaseWanActivity
import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.delay
import kotlinx.coroutines.launch

/**
 *
 *
 * @author Seven-C
 * @date 2021/8/18
 */
class WelcomeSplashActivity : BaseWanActivity() {
    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        setContentView(R.layout.welcome_activity_splash)
        requestPermission(Manifest.permission.READ_EXTERNAL_STORAGE) {
//            LogUtils.dTag(DEBUG_TAG,"requestPermission $it")
            lifecycleScope.launch(Dispatchers.Default) {
                delay(1500)
//                ARouterHelper.startActivity(ARouterUrl.Login.MainActivity)
//                ARouterHelper.startActivity(ARouterUrl.Welcome.AdActivity)
                delay(200)
                finish()
            }
        }
    }
}